﻿using System;
using System.Runtime.InteropServices;
using System.Runtime.InteropServices.ComTypes;
using System.Text;

namespace RegisterShellExtensions
{
	

	// Make these constants


	// GetCommandString uFlags


	public class Helpers
	{
		#region Win32 Imports

		[DllImport("shell32")]
		internal static extern uint DragQueryFile(uint hDrop, uint iFile, StringBuilder buffer, int cch);

		[DllImport("user32")]
		internal static extern HMenu CreatePopupMenu();

		[DllImport("user32")]
		internal static extern bool InsertMenuItem(HMenu hmenu, uint uposition, uint uflags, ref MENUITEMINFO mii);

		// MF_BYCOMMAND MF_BYPOSITION MF_STRING MF_POPUP
		[DllImport("user32")]
		internal static extern bool AppendMenu(HMenu hmenu, MFMENU uflags, IntPtr uIDNewItemOrSubmenu, String text);

		[DllImport("user32")]
		internal static extern bool InsertMenu(HMenu hmenu, int position, MFMENU uflags, IntPtr uIDNewItemOrSubmenu, String text);
		#endregion
	}
}